package com.qf.function.Ttst;

import com.qf.function.pojo.User;

import java.util.function.Consumer;
import java.util.function.Supplier;

/*
 *@Description:
 *@author:刘哥
 *@Date:86180 2022/9/2 11:47
 */
public class UserTest {
    public void proccessUser(Consumer<User> consumer){
        User user=new User();
        user.setName("张三");
        user.setAddresss("北京");
        user.setAge(18);
        consumer.accept(user);

    }
    public void processUser(Supplier<User> supplier){
        User user=supplier.get();
        String name = user.getName();
        System.out.println(name.toUpperCase());
    }
}
